import { useLocalStorage } from "@/hooks/useLocalStorage"
import { RootState } from "@/store"
import { Module } from "vuex"
import { IDeviceInfoActions, IDeviceInfoGetter, IDeviceInfoMutations, IDeviceInfoState } from "./types"
const { setLocalStorage, getLocalStorage } = useLocalStorage()
const state: IDeviceInfoState = {
    devicesInfo: [],
    component: {
        header: '设备信息',
        descFolder: {
            wsPort: 'WS端口号',
            status: '运行状态',
            pos: '位置',
        }
    }
}

const actions: IDeviceInfoActions = {

}

const mutations: IDeviceInfoMutations = {
    _setDevicesInfo(state: IDeviceInfoState, payload) {
        state.devicesInfo = payload
    }

}
const getters: IDeviceInfoGetter = {
}

export const deviceInfo: Module<IDeviceInfoState, RootState> = {
    namespaced: true,
    state,
    actions,
    mutations,
    getters
}
